
function toObject(query){
    query=query.slice(1);
    let obj={};
    let arr=query.split('&');
    arr.forEach((item)=>{
        let arr1=item.split('=')
        obj[arr1[0]]=arr1[1];
    })

    return obj;
}